Skip to content

fix: use observation_time for forecast datetime field#71

Merged
null8626 merged 1 commit into
null8626:mainfrom
Koloss0:fix/client-get-raises-keyerror
May 20, 2026
Merged

fix: use observation_time for forecast datetime field#71
null8626 merged 1 commit into
null8626:mainfrom
Koloss0:fix/client-get-raises-keyerror

Conversation

@Koloss0
Copy link
Copy Markdown
Contributor

@Koloss0 Koloss0 commented May 18, 2026

The localObsDateTime field seems to have been removed from the wttr.in JSON response as a KeyError is currently being raised every time Client.get is called. Fixed using the current_time field instead, and assuming the date to be today's date.

@codacy-production
Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 0 duplication

Metric Results
Complexity 0
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

Copy link
Copy Markdown
Owner

@null8626 null8626 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, thank you so much for this pull request! ❤️ Apologies for the three-day delay, as this pull request appeared when I was in the middle of my final exams. Will publish a new release carrying this patch! ❤️

@null8626 null8626 merged commit 7e4d807 into null8626:main May 20, 2026
1 check passed
null8626 added a commit that referenced this pull request May 20, 2026
@null8626
Copy link
Copy Markdown
Owner

null8626 commented May 20, 2026

@Koloss0 Your patch has been published to PyPI under v2.2.2! ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants